package Dict;

/**
 * Enum definition: PropGenreValue.
 *
 * @author OpenORB Compiler
*/
public final class PropGenreValue implements org.omg.CORBA.portable.IDLEntity
{
    /**
     * Enum member MASC value 
     */
    public static final int _MASC = 0;

    /**
     * Enum member MASC
     */
    public static final PropGenreValue MASC = new PropGenreValue(_MASC);

    /**
     * Enum member FEM value 
     */
    public static final int _FEM = 1;

    /**
     * Enum member FEM
     */
    public static final PropGenreValue FEM = new PropGenreValue(_FEM);

    /**
     * Internal member value 
     */
    private final int _PropGenreValue_value;

    /**
     * Private constructor
     * @param  the enum value for this new member
     */
    private PropGenreValue( final int value )
    {
        _PropGenreValue_value = value;
    }

    /**
     * Maintains singleton property for serialized enums.
     * Issue 4271: IDL/Java issue, Mapping for IDL enum.
     */
    public java.lang.Object readResolve() throws java.io.ObjectStreamException
    {
        return from_int( value() );
    }

    /**
     * Return the internal member value
     * @return the member value
     */
    public int value()
    {
        return _PropGenreValue_value;
    }

    /**
     * Return a enum member from its value.
     * @param value An enum value
     * @return An enum member
         */
    public static PropGenreValue from_int( int value )
    {
        switch ( value )
        {
        case 0:
            return MASC;
        case 1:
            return FEM;
        }
        throw new org.omg.CORBA.BAD_OPERATION();
    }

    /**
     * Return a string representation
     * @return a string representation of the enumeration
     */
    public java.lang.String toString()
    {
        switch ( _PropGenreValue_value )
        {
        case 0:
            return "MASC";
        case 1:
            return "FEM";
        }
        throw new org.omg.CORBA.BAD_OPERATION();
    }

}
